using System;
using System.Collections.Generic;
using System.Text;

namespace ControladorDifuso.Normas.T_Normas
{
    public class Hamacher:ControladorDifuso.Normas.Norma
    {
        private decimal gamma;

        public decimal Gamma
        {
            get
            {
                return this.gamma;
            }
            set
            {
                if (value > 0)
                    this.gamma = value;
            }
        }
        public override decimal calcular(decimal a, decimal b)
        {
            return (a * b) / (this.gamma + (1-this.gamma)*(a + b - a * b));
        }

        public override string ToString()
        {
            return " y ";
        }
    }
}
